package com.bdqn.service;

import com.bdqn.mapper.SupplierMapper;
import com.bdqn.pojo.Supplier;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service("supplierService")
public class SupplierServiceImpl implements SupplierService{

    @Resource
    private SupplierMapper supplierMapper;
    @Override
    public List<Supplier> queryPageByRealNameAndRoleId(int pageIndex, int pageSize, String supCode, String supName) {
        return supplierMapper.queryPageByRealNameAndRoleId(pageIndex,pageSize,supCode,supName);
    }
    @Override
    public int getCount() {
        return supplierMapper.getCount();
    }
    @Override
    public List<Supplier> getAll() {
        return supplierMapper.getAll();
    }

    @Override
    public int add(Supplier supplierList) {
        return supplierMapper.add(supplierList);
    }

    @Override
    public Supplier getSupplier(int supId) {
        return supplierMapper.getSupplier(supId);
    }
    @Override
    public int upd(Supplier supplier) {
        return supplierMapper.upd(supplier);
    }

    @Override
    public int del(int supId) {
        return supplierMapper.del(supId);
    }
}
